//
//  HBPhotoManager.h
//  HBPhotoPicker
//
//  Created by hibo on 2019/5/20.
//  Copyright © 2019 hibo. All rights reserved.
//

#import <Foundation/Foundation.h>
#import "HBAlbumModel.h"
#define HBScreenWidth  [[UIScreen mainScreen] bounds].size.width
#define HBScreenHeight [[UIScreen mainScreen] bounds].size.height
#define HBScreenScale  [UIScreen mainScreen].scale
#define HBIS_X (HBScreenHeight==812.0||HBScreenHeight==896.0?1:0)
#define STATUSHEIGHT (HBIS_X==1?44.0:20.0)
#define HBNAVHEIGHT (HBIS_X==1?88.0:64.0)
#define HBBarHEIGHT (HBIS_X==1?83.0:49)
#define HBBarOffset (HBIS_X==1?34.0:0.0)

NS_ASSUME_NONNULL_BEGIN

typedef enum {
    HBPhotoSelectTypeCommon = 0,//选择视频图片
    HBPhotoSelectTypeImage,     //选择图片
    HBPhotoSelectTypeVideo,     //选择视频
} HBPhotoSelectType;

@interface HBPhotoManager : NSObject

//相册列表
@property (nonatomic, strong) NSMutableArray<HBAlbumModel *> *collectionList;
//选择的最大可选数量,默认9张
@property (nonatomic, assign) NSInteger maxCount;
//选择类型 默认选择图片视频
@property (nonatomic, assign) HBPhotoSelectType selectType;

//获取所有相册
-(void)getAllCollection;

//显示图片选择器
+(void)showPhotoControllerType:(HBPhotoSelectType)type maxCount:(NSInteger)maxCount result:(void(^)(NSArray *assets))block;

//获取图片信息
+(void)getPhotoInfoWithAsset:(PHAsset*)asset targetSize:(CGSize)targetSize result:(void(^)(UIImage *image,PHAssetMediaType mediaType))block;

@end

NS_ASSUME_NONNULL_END
